package com.itsm.example.incident.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.itsm.example.incident.bo.Incident;
import com.itsm.example.incident.flow.bo.IncidentContext;
import com.itsm.example.statemachine.bo.ItsmEvent;

import java.util.List;

/**
 * 事件业务层接口
 */
public interface IncidentService extends IService<Incident> {

    /**
     * 新建事件工单
     * @return
     */
    Incident addAndProcess(IncidentContext context);

    /**
     * 流程流转
     * @return
     */
    Incident process(IncidentContext context);

    /**
     * 获取下一步事件
     * @return
     */
    List<ItsmEvent> getNextStep(IncidentContext context);
}
